<template>
  <el-carousel class="a" :interval="4000" type="card" height="200px">
    <el-carousel-item v-for="item in imgs" :key="item.image">
      <img :src="item.image" width="280px" height="200px" alt="carousel image">
    </el-carousel-item>
  </el-carousel>
</template>


<script>
export default {
  data() {
    return {
      imgs: [
        { image: require('../assets/xunhuan.png') },
        { image: require('../assets/xunhuan.png') },
        { image: require('../assets/xunhuan.png') }
        // 确保图片路径正确
      ]
    }
  }
}
</script>
<style lang="less" scoped>
.el-carousel__item h3 {
    color: #475669;
    font-size: 14px;
    opacity: 0.75;
    line-height: 200px;
    margin: 0;
  }
  
  .el-carousel__item:nth-child(2n) {
    background-color: #d3dce6;
  }
  
  .el-carousel__item:nth-child(2n+1) {
    background-color: #d3dce6;
  }
  .a{
    width: 550px;
    height: 350px;
  }
</style>
